#ifndef COIN_H
#define COIN_H

#include <QObject>
#include<QGraphicsPixmapItem>
#include<QPropertyAnimation>

class coin : public QObject,public QGraphicsPixmapItem
{
    Q_OBJECT
    Q_PROPERTY(QPointF pos READ getPos WRITE setPos1)
public:
    explicit coin(const QPixmap& pixmap,qreal coin_x,qreal coin_y,QObject *parent = nullptr);
    QPropertyAnimation* coinmove;
    QPointF getPos() const
    {
        return m_pos;
    }
    void setPos1(const QPointF &pos);


private:
    QPointF m_pos;

};

#endif // COIN_H
